using AZROLESLib;

namespace AzManContrib.MVC.Decorators
{
    public class AzManAuthorizationStoreDecorator : IAzManAuthorizationStore
    {

        private readonly IAzAuthorizationStore _surrogate;

        public AzManAuthorizationStoreDecorator(IAzAuthorizationStore surrogate)
        {
            _surrogate = surrogate;
        }

        public object GetProperty(int lPropId, object varReserved)
        {
            return _surrogate.GetProperty(lPropId, varReserved);
        }

        public void SetProperty(int lPropId, object varProp, object varReserved)
        {
            _surrogate.SetProperty(lPropId, varProp, varReserved);
        }

        public void AddPropertyItem(int lPropId, object varProp, object varReserved)
        {
            _surrogate.AddPropertyItem(lPropId, varProp, varReserved);
        }

        public void DeletePropertyItem(int lPropId, object varProp, object varReserved)
        {
            _surrogate.DeletePropertyItem(lPropId, varProp, varReserved);
        }

        public void AddPolicyAdministrator(string bstrAdmin, object varReserved)
        {
            _surrogate.AddPolicyAdministrator(bstrAdmin, varReserved);
        }

        public void DeletePolicyAdministrator(string bstrAdmin, object varReserved)
        {
            _surrogate.DeletePolicyAdministrator(bstrAdmin, varReserved);
        }

        public void AddPolicyReader(string bstrReader, object varReserved)
        {
            _surrogate.AddPolicyReader(bstrReader, varReserved);
        }

        public void DeletePolicyReader(string bstrReader, object varReserved)
        {
            _surrogate.DeletePolicyReader(bstrReader, varReserved);
        }

        public void Initialize(int lFlags, string bstrPolicyUrl, object varReserved)
        {
            _surrogate.Initialize(lFlags, bstrPolicyUrl, varReserved);
        }

        public void UpdateCache(object varReserved)
        {
            _surrogate.UpdateCache(varReserved);
        }

        public void Delete(object varReserved)
        {
            _surrogate.Delete(varReserved);
        }

        public IAzApplication OpenApplication(string bstrApplicationName, object varReserved)
        {
            return _surrogate.OpenApplication(bstrApplicationName, varReserved);
        }

        public IAzApplication CreateApplication(string bstrApplicationName, object varReserved)
        {
            return _surrogate.CreateApplication(bstrApplicationName, varReserved);
        }

        public void DeleteApplication(string bstrApplicationName, object varReserved)
        {
            _surrogate.DeleteApplication(bstrApplicationName, varReserved);
        }

        public IAzApplicationGroup CreateApplicationGroup(string bstrGroupName, object varReserved)
        {
            return _surrogate.CreateApplicationGroup(bstrGroupName, varReserved);
        }

        public IAzApplicationGroup OpenApplicationGroup(string bstrGroupName, object varReserved)
        {
            return _surrogate.OpenApplicationGroup(bstrGroupName, varReserved);
        }

        public void DeleteApplicationGroup(string bstrGroupName, object varReserved)
        {
            _surrogate.DeleteApplicationGroup(bstrGroupName, varReserved);
        }

        public void Submit(int lFlags, object varReserved)
        {
            _surrogate.Submit(lFlags, varReserved);
        }

        public void AddDelegatedPolicyUser(string bstrDelegatedPolicyUser, object varReserved)
        {
            _surrogate.AddDelegatedPolicyUser(bstrDelegatedPolicyUser, varReserved);
        }

        public void DeleteDelegatedPolicyUser(string bstrDelegatedPolicyUser, object varReserved)
        {
            _surrogate.DeleteDelegatedPolicyUser(bstrDelegatedPolicyUser, varReserved);
        }

        public void AddPolicyAdministratorName(string bstrAdmin, object varReserved)
        {
            _surrogate.AddPolicyAdministratorName(bstrAdmin, varReserved);
        }

        public void DeletePolicyAdministratorName(string bstrAdmin, object varReserved)
        {
            _surrogate.DeletePolicyAdministratorName(bstrAdmin, varReserved);
        }

        public void AddPolicyReaderName(string bstrReader, object varReserved)
        {
            _surrogate.AddPolicyReaderName(bstrReader, varReserved);
        }

        public void DeletePolicyReaderName(string bstrReader, object varReserved)
        {
            _surrogate.DeletePolicyReaderName(bstrReader, varReserved);
        }

        public void AddDelegatedPolicyUserName(string bstrDelegatedPolicyUser, object varReserved)
        {
            _surrogate.AddDelegatedPolicyUserName(bstrDelegatedPolicyUser, varReserved);
        }

        public void DeleteDelegatedPolicyUserName(string bstrDelegatedPolicyUser, object varReserved)
        {
            _surrogate.DeleteDelegatedPolicyUserName(bstrDelegatedPolicyUser, varReserved);
        }

        public void CloseApplication(string bstrApplicationName, int lFlag)
        {
            _surrogate.CloseApplication(bstrApplicationName, lFlag);
        }

        public string Description
        {
            get { return _surrogate.Description; }
            set { _surrogate.Description = value; }
        }

        public string ApplicationData
        {
            get { return _surrogate.ApplicationData; }
            set { _surrogate.ApplicationData = value; }
        }

        public int DomainTimeout
        {
            get { return _surrogate.DomainTimeout; }
            set { _surrogate.DomainTimeout = value; }
        }

        public int ScriptEngineTimeout
        {
            get { return _surrogate.ScriptEngineTimeout; }
            set { _surrogate.ScriptEngineTimeout = value; }
        }

        public int MaxScriptEngines
        {
            get { return _surrogate.MaxScriptEngines; }
            set { _surrogate.MaxScriptEngines = value; }
        }

        public int GenerateAudits
        {
            get { return _surrogate.GenerateAudits; }
            set { _surrogate.GenerateAudits = value; }
        }

        public int Writable
        {
            get { return _surrogate.Writable;}
        }

        public object PolicyAdministrators
        {
            get { return _surrogate.PolicyAdministrators; }
        }

        public object PolicyReaders
        {
            get { return _surrogate.PolicyReaders; }
        }

        public IAzApplications Applications
        {
            get { return _surrogate.Applications; }
        }

        public IAzApplicationGroups ApplicationGroups
        {
            get { return _surrogate.ApplicationGroups; }
        }

        public object DelegatedPolicyUsers
        {
            get { return _surrogate.DelegatedPolicyUsers; }
        }

        public string TargetMachine
        {
            get { return _surrogate.TargetMachine; }
        }

        public int ApplyStoreSacl
        {
            get { return _surrogate.ApplyStoreSacl; }
            set { _surrogate.ApplyStoreSacl = value; }
        }

        public object PolicyAdministratorsName
        {
            get { return _surrogate.PolicyAdministratorsName; }
        }

        public object PolicyReadersName
        {
            get { return _surrogate.PolicyAdministratorsName; }
        }

        public object DelegatedPolicyUsersName
        {
            get { return _surrogate.DelegatedPolicyUsersName; }
        }

        public IAzManApplication OpenApplication(string bstrApplicationName)
        {
            return new AzManApplicationDecorator(OpenApplication(bstrApplicationName, null));
        }
    }
}
